package ljl.alg.jianzhioffer.round3.easy;

public class _53_missingNumber {

    public int missingNumber(int[] nums) {
        int l = 0, r = nums.length - 1;
        while (l <= r) {
            int m = (l + r) >>> 1;
            if (nums[m] <= m)
                l = m + 1;
            else
                r = m - 1;
        }
        return l;
    }

}
